{% extends "tpls/layout1.html" %}

{% block title %}日常菜单{% endblock %}

{% block style %}
<link rel="stylesheet" href="/vendors/wangEditor/wangEditor.min.css"/>
<!-- inject:css -->
<link rel="stylesheet" href="/dist/styles/build/bd_menu_form.min.1476270773013.css"/>
<!-- endinject -->
{% endblock %}
{% block content %}

{{ include('components/bdheader.html') }}
{{ include('components/sidemenu.html') }}
<div class="main-content">
    <form>
        <table>
            <tr>
                <td>标题</td>
                <td>
                    <input name="title" type="text" class="field"/>
                </td>
            </tr>
            <tr>
                <td width="60">缩略图</td>
                <td>
                    <input name="thumbnail" type="file" class="field" />
                    <span style="color:red">图片尺寸: 600x400</span>
                    <div class="thumbnail-path">
                        <a href="" target="_blank"></a>
                    </div>
                </td>
            </tr>

            <tr>
                <td>主料</td>
                <td>
                    <input name="main" type="text" class="main-staff"/>
                </td>
            </tr>

            <tr>
                <td>辅料</td>
                <td>
                    <input name="assist" type="text" class="assist-staff"/>
                </td>
            </tr>

            <tr>
                <td>摘要</td>
                <td>
                    <textarea name="summary" rows="4" style="border: 1px solid #d0d0d0;width: 100%;padding: 8px;border-radius: 4px;"></textarea>
                </td>
            </tr>

            <tr>
                <td>正文</td>
                <td>
                    <textarea id="content-field" name="content"></textarea>
                </td>
            </tr>
            <tr>
                <td width="60">状态</td>
                <td>
                    <label class="radio-inline status">
                        <input type="radio" name="status" value="1" checked="checked"> 存草稿
                    </label>
                    <label class="radio-inline status">
                        <input type="radio" name="status" value="2"> 已审核
                    </label>
                </td>
            </tr>
            <tr>
                <td width="80">每周推荐</td>
                <td>
                    <label class="radio-inline isRecommend">
                        <input type="radio" name="isRecommend" value="0" checked="checked"> 否
                    </label>
                    <label class="radio-inline isRecommend">
                        <input type="radio" name="isRecommend" value="1"> 是
                    </label>
                </td>
            </tr>
            <tr>
                <td>&nbsp;</td>
                <td>&nbsp;</td>
            </tr>

            <tr>
                <td>&nbsp;</td>
                <td>
                    <div class="btn btn-submit">提交</div>
                </td>
            </tr>
        </table>

    </form>
</div>

{% endblock %}

{% block script %}
<script>
    var tmp = '{{ id }}';
    if(tmp && tmp !== '0') {
        window.menuId = tmp;
        $('form').append('<input type="hidden" name="thumbnail_org" id="thumbnail_org"/>')
    }
</script>

<script src="/vendors/wangEditor/wangEditor.min.js"></script>
<!-- inject:js -->
<script src="/dist/scripts/build/bd_menu_form.min.1476270773013.js"></script>
<!-- endinject -->
{% endblock %}